# negating conditions that fail
output1__negate_failing_conditions := true if {
    # every condition in this rule succeeds
    not false
    not 1 == 2
    not input.no_such_path
}

# negating conditions that succeed
output2__negate_successful_conditions := true if {
    # every condition in this rule fails
    not true
    not 1 == 1
    not 1
    not 0
    not "str"
    not ""
    not null
}

# the intuitive behavior
output1 := true if {
    not input.no_such_field  # condition succeeds
}

# the unintuitive behavior
output2 := true if {
    not upper(input.no_such_field)  # condition fails
}

helper_var := upper(input.no_such_field)
output3 := true if {              # rule succeeds
    not helper_var                  # condition succeeds
}
